import { lazy } from 'react'
import { HomeOutlined, GoldOutlined, UserOutlined, BarChartOutlined } from '@ant-design/icons'


const router = [
  {
    title: '首页',
    // icon: 'blog-home',
    icon: () => <HomeOutlined/>,
    key: '/app/home',
    path: '/app/home',
    parentPaths: null,
    component: lazy(() => import('@/pages/Home'))
  },
  {
    title: '产品管理',
    icon:() => <GoldOutlined/>,
    key: '/app/wx',
    path: '/app/wx',
    parentPaths: null,
    children: [
      {
        title: '微信端配置项',
        key: '/app/wx/chat',
        path: '/app/wx/chat',
        parentPaths: ['/app/wx'],
        component: lazy(() => import('@/pages/WX/Chat'))
      },
      {
        title: '支付宝端配置项',
        key: '/app/wx/space',
        path: '/app/wx/space',
        parentPaths: ['/app/fe'],
        component: lazy(() => import('@/pages/WX/SpaceFriends'))
      }
    ]
  },
  {
    title: '用户管理',
    icon: () => <UserOutlined/>,
    key: '/app/user',
    path: '/app/user',
    parentPaths: null,
    children: [
      {
        title: '用户数据',
        key: '/app/user/userdata',
        path: '/app/user/userdata',
        parentPaths: ['/app/user'],
        component: lazy(() => import('@/pages/User/UserData'))
      }
    ],
  },
  {
    title: '数据分析看板',
    icon: () => <BarChartOutlined/>,
    key: '/app/dashboard',
    path: '/app/dashboard',
    parentPahts: null,
    children: [
      {
        title: '代码自动打包提交',
        key: '/app/dashboard/analyse',
        path: '/app/dashboard/analyse',
        parentPahts: ['/app/dashboard'],
        component: lazy(() => import('@/pages/Analyse'))
      }
    ]
  }
]

export default router